package com.dly.blog.exception;

import cn.hutool.log.Log;
import com.dly.blog.content.ExceptionContent;
import lombok.Data;

/**
 * @Author: DaiLiYu
 * @Date: 2023/7/17 15:23
 */
public enum LogExceptionEnum {

    GET_OPLOG_ANNOTATION(new LogException(ExceptionContent.LogException + 1, "获取日志注解失败"));

    LogExceptionEnum(LogException logException){
        this.logException = logException;
    }

    private final LogException logException;

    public LogExceptionEnum.LogException getFileException() {
        return logException;
    }


    public static class LogException extends GlobalException{

        private static final String MODULE = "Log";

        public LogException(int code, String message) {
            super(code, message, MODULE);
        }
    }
}
